﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using Microsoft.Practices.Unity;
using System.Web.Mvc;
using RecipeBook.Business.EntityFramework;

namespace RecipeBook.UI.Web
{
    public static class Bootstrapper
    {
        public static void ConfigureUnityContainer()
        {
            IUnityContainer container = new UnityContainer();

            container.RegisterType<IRecipeRepository, RecipeRepository>();

            ControllerBuilder.Current.SetControllerFactory(new UnityControllerFactory(container));
        }
    }
}